package cn.kgc.jjl.send;

import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.net.Socket;
import java.net.UnknownHostException;

public class Demo02 {
	public static void main(String[] args) throws IOException {
		
		Socket s = new Socket("192.168.1.173",10010);
		OutputStream os = s.getOutputStream();
		os.write("吴明泽别吃粑粑了".getBytes());
		InputStream is = s.getInputStream();
		byte[] arr =new byte[1024];
		int len = is.read(arr);
		String str = new String(arr,0,len);
		System.out.println("客户端"+ str);
		
		is.close();
		os.close();
	
	}

}
